check-types-mini
Check the types of your options object's values after user has customised them
Install
npm i check-types-mini
Quick Take
import { strict as assert } from "assert";
import checkTypesMini from "check-types-mini";
assert.throws(() => {
checkTypesMini(
checkTypesMini(
{
option1: "setting1",
option2: "false",
option3: false,
},
{
option1: "setting1",
option2: false,
option3: false,
}
),
/not boolean but string/g
);
});
Documentation
Please visit codsen.com for a full description of the API and examples.
Licence
MIT License
Copyright (c) 2010-2020 Roy Revelt and other contributors
